import request from "@/router/axios";

export const getActivityPageList = (params) => {
  return request({
    url: "/admin/activity/list",
    method: "post",
    data: params,
  });
};

export const getActivityItemDetails = (row) => {
  return request({
    url: "/admin/activity/detail",
    method: "post",
    data: row,
  });
};


export const updateActivityItem = (row) => {
  return request({
    url: "/admin/activity/edit",
    method: "post",
    data: row,
  });
};
export const delActivityItem = (row) => {
  return request({
    url: "/admin/activity/delete",
    method: "post",
    data: row,
  });
};



// 活动订单
export const getActivityOrderPageList = (params) => {
  return request({
    url: "/admin/activity/order/list",
    method: "post",
    data: params,
  });
};
export const getActivityOrderDetail = (params) => {
  return request({
    url: "/admin/activity/order/detail",
    method: "post",
    data: params,
  });
};
// 活动属性
export const getActivityAttrList = (params) => {
  return request({
    url: "/admin/activity/attr/list",
    method: "post",
    data: params,
  });
};

export const addActivityAttrItem = (params) => {
  return request({
    url: "/admin/activity/attr/add",
    method: "post",
    data: params,
  });
};
export const editActivityAttrItem = (params) => {
  return request({
    url: "/admin/activity/attr/edit",
    method: "post",
    data: params,
  });
};
export const delActivityAttrItem = (params) => {
  return request({
    url: "/admin/activity/attr/delete",
    method: "post",
    data: params,
  });
};

// 活动匀速
export const getActivityRankList = (params) => {
  return request({
    url: "/admin/activity/rank/list",
    method: "post",
    data: params,
  });
};

export const addActivityRankItem = (params) => {
  return request({
    url: "/admin/activity/rank/add",
    method: "post",
    data: params,
  });
};
export const editActivityRankItem = (params) => {
  return request({
    url: "/admin/activity/rank/edit",
    method: "post",
    data: params,
  });
};
export const delActivityRankItem = (params) => {
  return request({
    url: "/admin/activity/rank/delete",
    method: "post",
    data: params,
  });
};

// 活动类型
export const getActivityTypeList = (params) => {
  return request({
    url: "/admin/activity/type/list",
    method: "post",
    data: params,
  });
};

export const addActivityTypeItem = (params) => {
  return request({
    url: "/admin/activity/type/add",
    method: "post",
    data: params,
  });
};
export const editActivityTypeItem = (params) => {
  return request({
    url: "/admin/activity/type/edit",
    method: "post",
    data: params,
  });
};
export const delActivityTypeItem = (params) => {
  return request({
    url: "/admin/activity/type/delete",
    method: "post",
    data: params,
  });
};